* {
	margin: 0;
	padding: 0;
	/* 标准盒子 */
	box-sizing: border-box;
}

body,
html {
	font-family: Arial, Helvetica, sans-serif;
	background-color: #f8f8f8;
	/* 锁定背景 */
	background-attachment: fixed;
	/* 弹性布局 */
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	height: 100%;
	margin: 0 auto;
}

h1 {
	margin: 0.2rem;
	font-size: 1.2rem;
}

p {
	font-size: 1rem;
	line-height: 1.5rem;/* 行高 */
	font-weight: 100;/* 字体粗细 */
	margin: 1.2rem 0;
	letter-spacing: 0.1rem;/* 字间距 */
}

span {
	font-size: 0.8rem;
	margin: 1.2rem 0;
}

a {
	color: #333;
	font-size: 1rem;
	text-decoration: none;
	/* 下划线消失 */
}

.avatar-section {
	text-align: center;
	margin-bottom: 20px;
}

.avatar-preview {
	width: 100px;
	height: 100px;
	border-radius: 50%;
	background-color: #eee;
	margin: 0 auto 10px;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 2px solid #ddd;
}

.avatar-preview img {
	width: 100%;
	height: 100%;
	object-fit: cover;/* 图片填充方式 */
}

.avatar-preview p {
	font-size: 40px;
	color: #999;
}
/* 隐藏的文件上传输入框 */
.avatar-upload {
	display: none;
}



.container {
	/* 相对定位 */
	position: relative;
	background-color: #fff;
	border-radius: 18px;
	box-shadow: 0 14px 28px rgba(0, 0, 0, 0.25), 0 10px 10px rgba(0, 0, 0, 0.22);
	padding: 0.6rem;
	width: 50rem;
	height: 35rem;
	/* 溢出隐藏 */
	overflow: hidden;
	max-width: 100vw;
	min-height: 70vh;
}
/* 表单容器样式 */
.form-container form {
	background-color: #fff;
	display: flex;
	flex-direction: column;
	/* 使得主轴方向从默认row改变，使得主轴从水平变垂直方向*/
	padding: 0rem 1.8rem;
	height: 100%;
	justify-content: center;
	align-items: center;
}
/* 表单输入框样式 */
.form-container input {
	width: 100%;
	height: 2.2rem;
	text-indent: 1rem;/* 文本首行缩进 */
	border-style: none none solid none;
	/* 把input上 右 左边框取消 */
	/* 点击input边框消失 */
	outline: none;/* 去除轮廓 */
	margin: 0.6rem 0;
}
/* 表单按钮样式 */
.form-container button {
	background-color: #417dff;
	padding: 0.4rem 1rem;
	color: #fff;
	border: 1px solid #fff;
	/* outline: none; */
	cursor: pointer;
	border-radius: 0.7rem;
	transition: all 100ms ease-in;
	/* 加速 */
	margin: 0.6rem 0;
	/* font-size: 0.6rem; */
}

.form-container button:active {
	/* 点击按钮时候缩小 */
	transform: scale(0.95);
}

/* 切换按钮样式 */
#switch-signin,
#switch-signup {
	background: transparent;
	border-color: #fff;
	border: 1px solid #fff;
	/* outline: none; */
	cursor: pointer;/* 手型光标 */
	width: 5rem;
	border-radius: 0.7rem;
	transition: all 800ms ease-in;
	margin: 0.6rem 0;
	padding: 0.5rem 0;
	color: #fff;
}
/* 切换按钮点击效果 */
#switch-signin:active,
#switch-signup:active {
	/* 点击按钮时候缩小 */
	transform: scale(0.95);
}



.form-container {
	position: absolute;
	/* 绝对定位 */
	top: 0;
	height: 100%;
	transition: all 0.5s ease-in;
}

.sign-in-container {
	left: 0;
	width: 50%;
	z-index: 2;
}

.sign-up-container {
	left: 0;
	width: 50%;
	opacity: 0;
	z-index: 1;
}
/* 覆盖层样式 */
.overlay {
	background-color: #417dff;
	width: 200%;
	height: 100%;
	position: relative;
	left: -100%;
	transition: all 0.5s ease-in-out;
	color: white;
}
/* 覆盖层容器 */
.overlay-container {
	position: absolute;
	top: 0;
	right: 0;
	width: 50%;
	height: 100%;
	overflow: hidden;/* 溢出隐藏 */
	transition: all 0.5s ease-in-out;
	z-index: 100;
}
/* 覆盖层面板 */
.overlay-panel {
	position: absolute;
	top: 0;
	display: flex;
	flex-direction: column;/* 垂直布局 */
	justify-content: center;/* 垂直居中 */
	align-items: center;/* 水平居中 */
	width: 50%;
	height: 100%;
	padding: 0 2.2rem;
}
/* 右侧覆盖层 */
.overlay-right {
	right: 0;
}

/* 当点击注册,sign-in往右平移，overlay-container往左平移*/
.container.right-panel-active .overlay-container {
	transform: translateX(-100%);
}
.container.right-panel-active .sign-in-container {
	transform: translateX(100%);
}


.container.right-panel-active .sign-up-container {
	transform: translateX(100%);/* 向右平移 */
	opacity: 1; /* 变为可见状态 */
	z-index: 5;
	transition: all 0.5s ease-in-out;
}


/* overlay往右平移相对距离，自身的一半 */
.container.right-panel-active .overlay {
	transform: translateX(50%);
}
/* 左侧覆盖层平移效果 */
/* .container.right-panel-active .overlay-left {
	transform: translateX(0);
	transition: all 0.5s ease-in-out;
} */
/* 右侧覆盖层平移效果 */
/* .container.right-panel-active .overlay-right {
	transform: translateX(20%);
	transition: all 0.5s ease-in-out;
} */
